package cate.game.play.skill.passive.boss;

import cate.game.play.config.PlayCfgArgs;
import cate.game.play.fighter.Fighter;
import cate.game.play.proce.action.ctx.ActionCtx;
import cate.game.play.skill.passive.PassiveHandler;

/**
 * 场上每次有英雄死亡，自身增加5%伤害加深，5%伤害减免，持续到战斗结束无冷却时间
 */
public class 三人成众PH extends PassiveHandler {

	private int buff;

	//buff=？？
	@Override
	public void parse(String code) {
		PlayCfgArgs args = new PlayCfgArgs(code);
		buff = args.getInt("buff", 0);
	}

	@Override
	public void onOtherDead(ActionCtx action, Fighter killer, Fighter deader) {
		if(skill.owner.isDead()){
			return;
		}
		skill.owner.buff.tryAddByTid(action, buff);
	}
}
